package pers.cj.pdos.controller.init;

import pers.cj.pdos.entity.Industry;
import pers.cj.pdos.service.IIndustryService;
import pers.cj.pdos.utils.UuidUtils;

import java.util.ArrayList;
import java.util.List;

public class InitIndustry {


    public void init(IIndustryService industryService) {

        if (industryService.count() > 0) {
            return;
        }

        List<Industry> list = new ArrayList<>();
        list.add(new Industry(UuidUtils.getUUID(),"烟酒食品","fa fa-gift"));
        list.add(new Industry(UuidUtils.getUUID(),"家电数码","fa fa-television"));
        list.add(new Industry(UuidUtils.getUUID(),"服装箱包","fa fa-inbox"));
        list.add(new Industry(UuidUtils.getUUID(),"家装建材","fa fa-bank"));
        list.add(new Industry(UuidUtils.getUUID(),"母婴玩具","fa fa-github-alt"));
        list.add(new Industry(UuidUtils.getUUID(),"日化用品","fa fa-cube"));
        list.add(new Industry(UuidUtils.getUUID(),"文体图书","fa fa-book"));
        list.add(new Industry(UuidUtils.getUUID(),"汽修汽配","fa fa-car"));
        list.add(new Industry(UuidUtils.getUUID(),"其他行业","fa fa-list"));
        industryService.insertBatch(list);
    }
}
